package com.spring.processor;

import com.spring.service.BeanService;
import org.springframework.beans.BeansException;
import org.springframework.beans.factory.config.BeanFactoryPostProcessor;
import org.springframework.beans.factory.config.ConfigurableListableBeanFactory;
import org.springframework.stereotype.Component;

@Component
public class BeanFactoryProcessorExt implements BeanFactoryPostProcessor {
    @Override
    public void postProcessBeanFactory(ConfigurableListableBeanFactory configurableListableBeanFactory) throws BeansException {
       // BeanDefinition beanDefinition = configurableListableBeanFactory.getBeanDefinition("beanServiceImpl");
        BeanService beanService = configurableListableBeanFactory.getBean(BeanService.class);
        beanService.test();
    }
}
